<template>
  <el-menu
    v-show="this.$store.state.showhead"
    :default-active="activeIndex2"
    class="el-menu-demo"
    mode="horizontal"
    background-color="transparent"
    text-color="#fff"
    active-text-color="#ffd04b"
    @select="handleSelect"
  >
    <el-menu-item index="1"><i class="el-icon-camera"></i>学生</el-menu-item>
    <el-menu-item index="2" ><i class="el-icon-user"></i>班级</el-menu-item>
    <el-menu-item index="3" ><i class="el-icon-info"></i>专业</el-menu-item>
    <el-menu-item index="4"><i class="el-icon-house"></i>院系</el-menu-item>
    <el-menu-item index="5"><i class="el-icon-menu"></i>学会</el-menu-item>

    <el-menu-item index="6" style="margin-left:500px"
      ><i class="el-icon-document-add"></i>新建</el-menu-item
    >
    <el-menu-item index="7"><i class="el-icon-search"></i>查询</el-menu-item>
    
  </el-menu>
</template>

<script>
export default {
  data(){
    return{
      pages:['/table','/class','/major','/series','club','/add','/search']
    }
  },
  methods: {
    handleSelect(i) {
        this.$router.push({ path: this.pages[i-1] })
    },
  },
};
</script>

<style>
</style>